{% extends "base.html" %}
{% load render_extras %}


{%if p%}
{%block info%}

{%endblock%}
{%endif%}

{%block userlist%}
		{% if p %}
		<h3 class="index-title" style="font-size:2.8em">
		<img src="/static/user.png" /> <a href="javascript:void(0)" id="dtips" rel="{{p.name}}"> {{ p.name }} </a>
		</h3>

		<div>
			<div id="points">
				<table summary="Your Status" caption="Stats">
					<thead>
						<tr>
							<th>Rank</th>
							<th>Influence</th>
							<th title="upstream users in delicious networks">Leaders number</th>
							<th title="downstream users in delicious networks" class="last">Fans number</th>
						</tr>
					</thead>
					<tbody>
						<tr class="nobg">
							<td><span style="font-size: 1.6em; font-weight: 600; padding-left: 5px;">#{{p.urank}} </span></td>
							<td>
							
								<div class="bar_wrapper clearfix" title="{{p.score}}">
									<div class="bar">
										<span class="energybar" style="left: -{{p.score|barstyle:"120"}}px;"></span>
										<span class="overlay"></span>
									</div>
								</div>

							</td>
							<td><span style="font-size: 1.2em; font-weight: 600; padding-left: 5px;">{{p.leaders}}</span></td>
							<td class="last"><span style="font-size: 1.2em; font-weight: 600; padding-left: 5px;">{{p.followers}}</span></td>
						</tr>
				</tbody></table>
			</div>
		</div>
		{%endif%}
		<h3 id="community-list" class="index-title">
		</h3>
	<ul class="tab-nav fright">
			{% if p %}
			<li  {%if current == "l" %} class="current" {% endif%}><a href="/leader/{{ p.name }}" title="upstream users in delicious networks">My Leaders</a></li>
			<li {%if current == "f" %} class="current" {% endif%} ><a href="/follower/{{ p.name }}" title="downstream users in delicious networks">My Fans</a></li>
			{% endif %}
	</ul>
	<div class="clear"></div>

	<table class="leaderboard">
		<thead>
			<tr>
				<th width=150>Rank</th>
				<th width=150>User</th>
				<th width=200>Influence</th>
			</tr>
		</thead>
	</table>
	<div>
	<table id="table_container" style="position:relative;">
			{%for user in users%}
			<tr>
				<td width=180><span style="font-size:1.6em;font-weight:600;padding-left:5px;">{{user.urank}} </span></td>

				<td width=180><a class="username" id="user{{user.id}}" href="javascript: void(0)" rel="{{user.name}}">{{user.name}}</a></td>

				<td width=200>
				
					<div class="bar_wrapper clearfix" title="{{user.score}}">
						<div class="bar">
							<span class="energybar" style="left: -{{user.score|barstyle:"120"}}px;"></span>
							<span class="overlay"></span>
						</div>
					</div>

				</td>

			</tr>
		{%endfor%}
	</table>
	</div>

		<div style="">
			<div class="pagination">
				{% for link  in pagelist %}
				{% if link == currentPage %}
				<span class="current">{{link}}</span>
				{% else %}
				<a href="?page={{link}}">{{link}}</a>
				{% endif %}
				{% endfor %}
		</div>
		</div>
{%endblock%}
